package com.honglang.module.album.service;

import java.util.List;

import org.springframework.transaction.annotation.Transactional;

import com.honglang.common.tools.Pager;
import com.honglang.module.album.entity.Album;

public interface AlbumService {
	/**
	 * save album
	 * @param album
	 * @return
	 */
	@Transactional(readOnly = false)
	public Album save(Album album);
	
	
	
	/**
	 * delete a album 
	 * @param album
	 */
	@Transactional(readOnly = false)
	public void delete(Album album);
	
	/**
	 * delte a album
	 * @param albumId
	 */
	@Transactional(readOnly = false)
	public void deleteAlbum(Integer albumId);
	
	
	/**
	 * get one page of album ;
	 * @param pageSize
	 * @param pageNo
	 * @return
	 */
	@Transactional(readOnly = true)
	public Pager getPager(int pageSize,int pageNo);
	
	
	/**
	 * get  a list of album by ids;
	 * @param idList
	 * @return
	 */
	@Transactional(readOnly = true)
	public List<Album> getAlbumByIdList(List<Integer> idList);
	
	/**
	 * batch delete album;
	 * @param albumList
	 */
	@Transactional(readOnly = false)
	public void delete(List<Album> albumList);
	
	
	/**
	 * batch delete album
	 * @param albumIds
	 */
	@Transactional(readOnly = false)
	public void batchDeleteAlbum(String albumIds);
	
	
	/**
	 * get album by id;
	 * @param albumId
	 * @return
	 */
	@Transactional(readOnly = true)
	public Album getById(Integer albumId);
}
